import React from 'react'
import { MainLayout } from '../components'

const Home = React.lazy(() => import('../views/home'))
const ListManage = React.lazy(() => import('../views/listManage'))
const ListAdd = React.lazy(() => import('../views/listAdd'))
const Login = React.lazy(() => import('../views/login'))
const Set = React.lazy(() => import('../views/set'))
const Upload = React.lazy(() => import('../views/upload'))

export const routes = [{
	path: '/',
	element: <MainLayout><Home></Home></MainLayout>,
	meta: {
		title: '首页'
	}
}, {
	path: '/list/add',
	element: <MainLayout><ListAdd></ListAdd></MainLayout>,
	meta: {
		title: '列表添加'
	}
}, {
	path: '/list/manage',
	element: <MainLayout><ListManage></ListManage></MainLayout>,
	meta: {
		title: '列表管理'
	}
}, {
	path: '/upload',
	element: <MainLayout><Upload></Upload></MainLayout>,
	meta: {
		title: '上传'
	}
}, {
	path: '/set',
	element: <MainLayout><Set></Set></MainLayout>,
	meta: {
		title: '设置'
	}
}, {
	path: '/login',
	element: <Login></Login>,
	meta: {
		title: '登录',
		hidden: true
	}
}]
